<?php

namespace App\Http\Controllers\Admin;
use App\DTOS\Admin\ActiveRuleSearchDTO;
use App\DTOS\Admin\AlarmSearchDTO;
use App\DTOS\Admin\PayOrderDTO;
use App\DTOS\NeiGouDTO;
use App\Exceptions\ServiceException;
use App\Http\Controllers\Controller;
use App\Models\Customer;
use App\Models\Game\GameGoods;
use App\Models\Game\OnLine;
use App\Models\Game\OnLineInfo;
use App\Models\Game\PayOrder;
use App\Models\Game\Server;
use App\Services\Game\ActiveRuleService;
use App\Services\Game\AlarmService;
use App\Services\Game\DouyinService;
use App\Services\Game\NeigouService;
use App\Services\Game\PayOrderService;
use App\Services\Game\QzlService;
use App\Services\Game\UserMemberService;
use App\Services\Game\UserRoleService;
use App\Utils\InitUtils;
use App\Utils\MyLog;
use App\Utils\ResponseUtil;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\DB;


class AlarmController extends Controller
{

    private AlarmService $service;

    /**
     * FeedBackService constructor.
     * @param AlarmService $service
     */
    public function __construct(AlarmService $service)
    {
        $this->service = $service;
    }



    public function paginate()
    {


        $DTO = new AlarmSearchDTO(request()->all());
        $paginate = $this->service->paginate($DTO);
        $data = $paginate->items();

        $res = [];
        $res['code'] = 0;
        $res['data'] = $data;
        $res['count'] = $paginate->total();
        return ResponseUtil::json($res);
    }


}
